This script sets the status bar text to the current time when a button is pressed.
function setMessage(){ var now = new Date(); var statusStr = now.getHours()+':'; var statusMin = now.getMinutes(); if(parseInt(statusMin) < 10) statusStr += '0'; statusStr += statusMin; window.status = ("The time is "+statusStr); }